package com.sg.file.transform.provider.center;

import com.sg.file.transform.api.dto.TransformReqeust;
import it.sauronsoftware.jave.AudioAttributes;
import it.sauronsoftware.jave.EncodingAttributes;

/**
 * Created by asus on 2018/6/28.
 */
public class AudioTranscode extends FFmpegTranscode {

    @Override
    public EncodingAttributes getEncodeAttr(TransformReqeust transformReqeust) {
        //设置音频参数
        AudioAttributes audio = new AudioAttributes();
        //--acodec
        audio.setCodec("libmp3lame");
        //设置转换器参数
        EncodingAttributes attrs = new EncodingAttributes();
        attrs.setFormat(null);//-f
        attrs.setAudioAttributes(audio);

        return attrs;
    }


}
